<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="zh">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.6"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>SimpleModbusRTUPacket: modbus_master_context_t结构体 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectalign">
   <div id="projectname">SimpleModbusRTUPacket
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.9.6 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>首页</span></a></li>
      <li class="current"><a href="annotated.html"><span>类</span></a></li>
      <li><a href="files.html"><span>文件</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>类列表</span></a></li>
      <li><a href="classes.html"><span>类索引</span></a></li>
      <li><a href="functions.html"><span>类成员</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-attribs">Public 属性</a> &#124;
<a href="structmodbus__master__context__t-members.html">所有成员列表</a>  </div>
  <div class="headertitle"><div class="title">modbus_master_context_t结构体 参考</div></div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="_modbus_8h_source.html">Modbus.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-attribs" name="pub-attribs"></a>
Public 属性</h2></td></tr>
<tr class="memitem:a46a3ed8e094aa3f7937fc19e3362d6fd"><td class="memItemLeft" align="right" valign="top">uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structmodbus__master__context__t.html#a46a3ed8e094aa3f7937fc19e3362d6fd">slave_addr</a></td></tr>
<tr class="separator:a46a3ed8e094aa3f7937fc19e3362d6fd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae6831967792a33d6980e3a006141d806"><td class="memItemLeft" align="right" valign="top">void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structmodbus__master__context__t.html#ae6831967792a33d6980e3a006141d806">output</a> )(uint8_t *data, size_t data_length)</td></tr>
<tr class="memdesc:ae6831967792a33d6980e3a006141d806"><td class="mdescLeft">&#160;</td><td class="mdescRight">串口输出函数,当解析完成后，将调用此函数输出数据，不可为NULL。  <br /></td></tr>
<tr class="separator:ae6831967792a33d6980e3a006141d806"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa7d29db6de7fb9521c26dd52c552d9a7"><td class="memItemLeft" align="right" valign="top">size_t(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structmodbus__master__context__t.html#aa7d29db6de7fb9521c26dd52c552d9a7">request_reply</a> )(uint8_t *data, size_t data_length)</td></tr>
<tr class="memdesc:aa7d29db6de7fb9521c26dd52c552d9a7"><td class="mdescLeft">&#160;</td><td class="mdescRight">请求数据(读串口输入),当Modbus请求发出后，会调用此函数等待从机回应，不可为NULL。  <br /></td></tr>
<tr class="separator:aa7d29db6de7fb9521c26dd52c552d9a7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock">
<p class="definition">在文件 <a class="el" href="_modbus_8h_source.html">Modbus.h</a> 第 <a class="el" href="_modbus_8h_source.html#l00161">161</a> 行定义.</p>
</div><h2 class="groupheader">类成员变量说明</h2>
<a id="ae6831967792a33d6980e3a006141d806" name="ae6831967792a33d6980e3a006141d806"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae6831967792a33d6980e3a006141d806">&#9670;&#160;</a></span>output</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void(* modbus_master_context_t::output) (uint8_t *data, size_t data_length)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>串口输出函数,当解析完成后，将调用此函数输出数据，不可为NULL。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">data</td><td>串口输出数据的指针 </td></tr>
    <tr><td class="paramname">data_length</td><td>串口输出数据长度 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd></dd></dl>

<p class="definition">在文件 <a class="el" href="_modbus_8h_source.html">Modbus.h</a> 第 <a class="el" href="_modbus_8h_source.html#l00172">172</a> 行定义.</p>

</div>
</div>
<a id="aa7d29db6de7fb9521c26dd52c552d9a7" name="aa7d29db6de7fb9521c26dd52c552d9a7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa7d29db6de7fb9521c26dd52c552d9a7">&#9670;&#160;</a></span>request_reply</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t(* modbus_master_context_t::request_reply) (uint8_t *data, size_t data_length)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>请求数据(读串口输入),当Modbus请求发出后，会调用此函数等待从机回应，不可为NULL。 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">data</td><td>请求数据的指针 </td></tr>
    <tr><td class="paramname">data_length</td><td>请求数据的长度(最大) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>size_t 成功读取的数据长度 </dd></dl>

<p class="definition">在文件 <a class="el" href="_modbus_8h_source.html">Modbus.h</a> 第 <a class="el" href="_modbus_8h_source.html#l00182">182</a> 行定义.</p>

</div>
</div>
<a id="a46a3ed8e094aa3f7937fc19e3362d6fd" name="a46a3ed8e094aa3f7937fc19e3362d6fd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a46a3ed8e094aa3f7937fc19e3362d6fd">&#9670;&#160;</a></span>slave_addr</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t modbus_master_context_t::slave_addr</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>从机地址，主要指与此主机通信的从机地址 </p>

<p class="definition">在文件 <a class="el" href="_modbus_8h_source.html">Modbus.h</a> 第 <a class="el" href="_modbus_8h_source.html#l00163">163</a> 行定义.</p>

</div>
</div>
<hr/>该结构体的文档由以下文件生成:<ul>
<li><a class="el" href="_modbus_8h_source.html">Modbus.h</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6
</small></address>
</body>
</html>
